<h1>TiUDP Module 1.0</h1>
<h2>Description</h2>
<p>The UDP protocol is 1 of the transport protocols of the internet. Until now, the support of it was missing. But from now on, a complete new set of network services are in your range! With this module you can communicate with every UDP service in only a few lines of code. And the usual low-level socket knowlegde is not required! </p>
<h2>Accessing the apprate Module</h2>
<p>To access this module from JavaScript, you would do the following:</p>
<pre><code>var udpSocketModule = require("nl.icept.network.udp");
</code></pre>
<p>The udpSocketModule variable is a reference to the Module object. <br />
</p>
<p>Don't forget to list the module in tiapp.xml!</p>
<h2>Reference</h2>
<h3>createUDPSocket([options])</h3>
<p>Create the socket and returns it. Give a options object with a port key to bound to a specified port. With the timeout key, you can determe how much seconds a read option waits for data. Default timeout is 30 seconds.</p>
<h3>udpSocket.isReadable()</h3>
<p>Check if there is data to read on the socket. If not, the read call blocks until there is data to read or the timeout is hit.</p>
<h3>udpSocket.read(callback)</h3>
<p>Start to read data. The callback function is 1 or more times called, depending on the amount of data waiting.</p>
<h3>udpSocket.write(targetIP, targetPort, data)</h3>
<p>Send data to the targetPort on the targetIP. Data could be a string, blob or buffer.</p>
<h3>udpSocket.close()</h3>
<p>Close the socket. It's not longer possible to read or write on the socket.</p>
<h2>Usage</h2>
<p>See the example project for the complete usage.</p>
<h2>Author</h2>
<p>Martijn Bogaard <a href="&#109;&#97;&#105;&#108;&#116;&#111;&#58;&#109;&#97;&#114;&#116;&#105;&#106;&#110;&#64;&#105;&#99;&#101;&#112;&#116;&#46;&#110;&#108;">&#109;&#97;&#114;&#116;&#105;&#106;&#110;&#64;&#105;&#99;&#101;&#112;&#116;&#46;&#110;&#108;</a></p>
<h2>License</h2>
<p>After purchase in the Appcelerator Marketplace you get a unlimited, non-transferable 1 seat license. You are 
free to use this in a unlimited amount of projects but you are not allowed to (re)sell your license.</p>
<p>THIS SOFTWARE IS PROVIDED BY iCept Media ''AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DIRECT, 
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
POSSIBILITY OF SUCH DAMAGE.</p>